import { createRouter, createWebHistory } from 'vue-router'
import DatasetHome from '@/components/DatasetHome.vue'

const routes = [
  {
    path: '/',
    name: 'home',
    component: DatasetHome
  },
  {
    path: '/question-management',
    name: 'questionManagement',
    component: () => import('@/views/QuestionManagement.vue')
  },
  {
    path: '/question-detail/:id/:version/:title/:content/:source/:time/:active',
    name: 'questionDetail',
    component: () => import('@/views/QuestionDetail.vue'),
    props: true
  },
  {
    path: '/standard-management',
    name: 'standardManagement',
    component: () => import('@/views/StandardManagement.vue')
  },
  {
    path: '/standard-detail/:id/:originalId/:version',
    name: 'standardDetail',
    component: () => import('@/views/StandardDetail.vue'),
    props: true
  },
  {
    path: '/llm-answers',
    name: 'llmAnswers',
    component: () => import('@/views/LLMAnswer.vue')
  },
  {
    path: '/evaluation',
    name: 'evaluation',
    component: () => import('@/views/Evaluation.vue')
  },
  {
    path: '/evaluation/:taskId',
    name: 'EvaluationDetail',
    component: () => import('@/views/EvaluationDetail.vue'),
    props: true
  }
]

const router = createRouter({
  history: createWebHistory(),
  routes
})

export default router
